//
//  LGSystemDetailViewController.m
//  ligenyun
//
//  Created by Mac on 2018/3/24.
//  Copyright © 2018年 stoneobs@icloud.com. All rights reserved.
//

#import "LGSystemDetailViewController.h"

@interface LGSystemDetailViewController ()

@end

@implementation LGSystemDetailViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    self.title = @"消息正文";
    [self configSubView];
    // Do any additional setup after loading the view.
}

#pragma mark --subView
- (void)configSubView{
    UIImageView * imageView = [[UIImageView alloc] initWithFrame:self.tableView.bounds];
    imageView.image = [UIImage imageNamed:@"底部"];
    self.tableView.backgroundView = imageView;
    
    UIView * header = [[UIView alloc] initWithFrame:CGRectMake(0, 0, UIScreenWidth, 300)];
    
    STLabel * titleLable = [[STLabel alloc] initWithFrame:CGRectMake(0, 40, UIScreenWidth, 40)
                                                     text:@"消息正文"
                                                textColor:SecendTextColor
                                                     font:16
                                              isSizetoFit:NO
                                            textAlignment:NSTextAlignmentCenter];
    [header addSubview:titleLable];
    
    
    STLabel * wealcomeLable = [[STLabel alloc] initWithFrame:CGRectMake(15, titleLable.bottom, UIScreenWidth, 40)
                                                     text:@"尊敬的用户您好！"
                                                textColor:SecendTextColor
                                                     font:15
                                              isSizetoFit:NO
                                            textAlignment:NSTextAlignmentLeft];
    [header addSubview:wealcomeLable];
    
    
    STLabel * desLable = [[STLabel alloc] initWithFrame:CGRectMake(15, wealcomeLable.bottom + 30, UIScreenWidth - 30, 40)
                                                   text:@"      欢迎您使用礼根云平台，如您在使用平台的过程中遇到问题，请您与我们联系哦!"
                                                   textColor:SecendTextColor
                                                        font:15
                                                 isSizetoFit:NO
                                               textAlignment:NSTextAlignmentLeft];
    [NSString lableAutoAdjustheightWithLabel:desLable];
    [header addSubview:desLable];
    
    
    STLabel * timeLable = [[STLabel alloc] initWithFrame:CGRectMake(15, desLable.bottom + 100, UIScreenWidth, 40)
                                                        text:@"礼根云\n2018年03月24日13:51:56"
                                                   textColor:SecendTextColor
                                                        font:15
                                                 isSizetoFit:NO
                                               textAlignment:NSTextAlignmentRight];
    [header addSubview:timeLable];
    timeLable.right = UIScreenWidth - 15;
    header.height = timeLable.bottom;
    self.tableView.tableHeaderView = header;
}

@end
